Crate caves[][src]

Caves

A selection of key-value stores (kvs) with the following features:

  • Embedded
  • Thread-safe
  • Simple API; get/set/delete a key
  • Dev-friendly

The latter is the main reason for creating this crate. By dev-friendly we mean that all of the key-values stores provide the same interface with the same semantics. Therefore, the developer can use each kv interchangeably, according to their needs.

The only differences that the developer needs to know for each kv are:

  • Naming restrictions: Some kvs may have restrictions regarding the characters in a name. For instance, the file kv does not allow the / character.
  • Persistence guarantees: The kvs do not offer the same guarantees once the plug is pulled. For instance, the memory kv does not retain state when the power is lost.

The uniformity in the interface of the kvs is enforced by the Cave trait. See its definition for more info.

Modules

errors

Errors

res

Result type

Structs

FileCave

A key-value store that stores keys in files.

MemoryCave

A key-value store that stores keys in-memory.

RocksDBCave

A key-value store that stores keys in RocksDB.

Traits

Cave

A simple interface for key-value stores.